package dongshi.daddy.dongsrmutitidatasoucespringbootstarter.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.Map;

@ConfigurationProperties(prefix = "dongshi.daddy.multidatasource")
public class CustomDatasourceProperties {

    // 11用户配置的多数据源信息会设置到该map中，可能如下配置：
    /*
    dongshi.daddy.multidatasource.source_1.routingKey=source_1
    dongshi.daddy.multidatasource.source_1.host=23.23.23.23
    dongshi.daddy.multidatasource.source_1.port=3232
    dongshi.daddy.multidatasource.source_1.username=db_username
    dongshi.daddy.multidatasource.source_1.password=db_password
    dongshi.daddy.multidatasource.source_1.database=db
     */
    private Map<String, Map<String, Object>> datasoures;

    public Map<String, Map<String, Object>> getDatasoures() {
        return datasoures;
    }

    public void setDatasoures(Map<String, Map<String, Object>> datasoures) {
        this.datasoures = datasoures;
    }
}
